package thread.noticywait;

public class ThreadRun {

	public static void main(String[] args) {
		CommonEntity commonEntity=new CommonEntity();
		//必须要拿到同一个对象的锁,才能唤醒wait方法
		Thread th1=new Thread(new ThreadWait(commonEntity));
		Thread th2=new Thread(new ThreadNotify(commonEntity));
		th1.start();
		th2.start();
	}

}
